#include <iostream>
#include <memory>
#include "datetime.h"

using namespace std;

int main(int argc, const char** argv) {
    const wb::Date today;

    cout << today.toString();
    const char* fmt1 = "%F %T%n";
    const char* fmt2 = nullptr;
    cout << today.toString(fmt1);
    cout << today.toString(fmt2);
    cout << today.today().toString();
    cout << today.tomorrow().toString();
    cout << "tomorrow" << endl;
    const wb::Date tomorrow = today.tomorrow();
    cout << tomorrow.toString();
    auto tmtest = tomorrow.tmStruct();
    cout << "tm_sec		"    <<  tmtest->tm_sec   << endl;
    cout << "tm_min		"    <<  tmtest->tm_min   << endl;
    cout << "tm_hour		"   <<  tmtest->tm_hour  << endl;
    cout << "tm_mday		"   <<  tmtest->tm_mday  << endl;
    cout << "tm_mon		"    <<  tmtest->tm_mon   << endl;
    cout << "tm_year		"   <<  tmtest->tm_year  << endl;
    cout << "tm_wday		"   <<  tmtest->tm_wday  << endl;
    cout << "tm_yday		"   <<  tmtest->tm_yday  << endl;
    cout << "tm_isdst	"  <<  tmtest->tm_isdst << endl;

    return 0;
}